//
//  HeaderView.m
//  WuShiCity
//
//  Created by 王文晓 on 16/7/4.
//  Copyright © 2016年 chengjie. All rights reserved.
//

#import "HeaderView.h"
#import "SearchViewController.h"

@implementation HeaderView


//选择天气的轻拍
- (IBAction)WeatherTap:(UITapGestureRecognizer *)sender {
    
    if ([self.WeatherLabel.text isEqualToString:@"天气"]) {
        
        self.WeatherLabel.text = @"晴";
    }else{
        
        self.WeatherLabel.text = @"天气";
    }
    
    NSLog(@"天气");
}


//选择地址的轻拍
- (IBAction)AddressTap:(UITapGestureRecognizer *)sender {
    
    
    if ([self.AddressLabel.text isEqualToString:@"位置"]) {
        
        self.AddressLabel.text = @"西安";
    }else{
        
        self.AddressLabel.text = @"位置";
    }
    
    NSLog(@"位置");
}



//搜索按钮
- (IBAction)SearchButton:(UIButton *)sender {
   
//    SearchViewController *searchVC = [[SearchViewController alloc] initWithNibName:@"SearchViewController" bundle:nil];
     SearchViewController *searchVC = [[SearchViewController alloc] init];
    
    [self.naVC pushViewController:searchVC animated:NO];
 
}


// 二维码
- (IBAction)Qrcode:(UIButton *)sender {
   
    //    判断btn当前的title
    if ([sender.currentTitle isEqualToString:@"扫"]) {
        
        [sender setTitle:@"1233" forState:UIControlStateNormal];
        
    }
   
    NSLog(@"二维码");
}






@end
